package com.gxa.customer.service.Impl;

import com.gxa.common.pojo.SysMenu;
import com.gxa.common.pojo.SysRole;
import com.gxa.customer.mapper.PermissionMapper;
import com.gxa.customer.service.PermissionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class PermissionServiceImpl implements PermissionService {
    //根据角色获取菜单
    @Autowired
    private PermissionMapper permissionMapper;

    @Override
    public List<SysMenu> selectAllMenuByRoleId(Long roleId) {
        List<SysMenu> sysMenus = permissionMapper.selectAllMenuByRoleId(roleId);
        return sysMenus;
    }
}
